#ifndef GRID_H
#define GRID_H

#include "Object3D.h"
#include <QVector3D>

class Grid : public Object3D
{
    Q_OBJECT

    int m_tx, m_ty, m_tz;
    float ***m_data;
    float m_iso;

public:
    explicit Grid(const QVector3D& center = QVector3D(), QObject *parent = 0);

    void loadFromFile(const QString&);
    void loadFromRawFile(const QString&);

    void setIso(float iso);
    void incIso(int steps);

private:
    void drawGeometry(void) const;
    void processaCubo(QVector3D* pontos, float *densidades) const;
    void processaTetraedro(QVector3D* pontos, float *densidades) const;

};

#endif // GRID_H
